
public class Factorial {
	
	public Factorial()
	{
	}
	private double factorial(double n)
	{
		if (n==1)
			return 1;
		else
			return n*factorial(n-1);
	}
	public static void main(String[] args) {

		Factorial f = new Factorial();
		double m;
		for (int i=5; i<170; i+=5)
		{
		long before = System.nanoTime(); 
		m=f.factorial(i);
		long after =  System.nanoTime();
		long diff = after - before;
		System.out.print(i + "\t" + m + "\t" + diff + "\n");
		}

	}
}
